package io.gitee.zhangbinhub.admin.oauth.po

import io.swagger.annotations.ApiModel
import io.swagger.annotations.ApiModelProperty
import org.noear.solon.validation.annotation.NotBlank

@ApiModel("角色配置参数")
data class RolePo(
    @ApiModelProperty(name = "角色ID，更新时必填")
    var id: String? = null,
    @ApiModelProperty(name = "应用ID，更新时可不填", required = true)
    var appId: String? = null,
    @ApiModelProperty(name = "角色名称", required = true)
    @field:NotBlank(message = "角色名称不能为空")
    var name: String? = null,
    @ApiModelProperty(name = "角色编码", required = true)
    @field:NotBlank(message = "角色编码不能为空")
    var code: String? = null,
    @ApiModelProperty(name = "角色级别", required = true)
    var levels: Int = 1,
    @ApiModelProperty(name = "序号", required = true)
    var sort: Int = 0,
    @ApiModelProperty(name = "类型")
    var type: Int? = null,
    @ApiModelProperty(name = "关联用户ID")
    var userIds: MutableList<String> = mutableListOf(),
    @ApiModelProperty(name = "关联菜单ID")
    var menuIds: MutableList<String> = mutableListOf(),
    @ApiModelProperty(name = "关联模块功能ID")
    var moduleFuncIds: MutableList<String> = mutableListOf()
)
